﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.Text;

namespace MyBlog.BusinessInterface
{
    public interface IBLL<T> where T : class
    {
        void Add(T entity);

        void AddRange(IEnumerable<T> entities);

        void Update(T entity);

        void Delete(params object[] primaryKey);

        void Delete(T entity);

        void DeleteRange(IEnumerable<T> entities);

        T Get(params object[] primaryKey);

        T Get(T entity);

        List<T> GetAll(bool isTracking = true);

        List<T> GetAll(T model, bool isTracking = true);

        List<T> GetAll(T model, int page, int size, out int total, bool isTracking = true);
    }
}
